#ifndef _ZCUBE8Vertex_H_
#define _ZCUBE8Vertex_H_


class ZCube8Vertex : public ZCommonModel
{
public:
	struct CUBEVERTEX
	{
		D3DXVECTOR3 p;
		DWORD		color;

		enum { FVF = D3DFVF_XYZ | D3DFVF_DIFFUSE };
		enum { VertexNum = 8 };
	};

	struct CUBEINDEX
	{
		WORD _0, _1, _2;
	};

	ZCube8Vertex();
	virtual ~ZCube8Vertex();

	HRESULT Init() { return S_OK; }
	HRESULT Init( LPDIRECT3DVERTEXBUFFER9 &a_pVB, LPDIRECT3DINDEXBUFFER9 &a_pIB, INT a_iStartVB, INT a_iStartIB );
	HRESULT InitTexture( DWORD a_Color, DWORD a_OutLineColor=0xff0000ff );
	
	VOID Draw();
	VOID CleanUp();



private:
	HRESULT _InitVB( LPDIRECT3DVERTEXBUFFER9 &a_pVB );
	HRESULT _InitIB( LPDIRECT3DINDEXBUFFER9 &a_pIB );

	INT m_iStartVB;
	INT m_iStartIB;

	DWORD m_Color;

	

};

#endif